package ff;

import java.awt.event.*;

import javax.swing.*;

import dao.Dao;

public class Ff_update implements ActionListener{
	private String name,sex,bed,room,money,man,mz,family,tellphone,IDcard,data;
	private JButton btn;
	public Ff_update(String d_name,String d_sex,String d_bed,String d_room,String d_money,String d_man,String d_mz,String d_family,String d_tellphone,String d_IDcard,String d_data,JButton btn){
		this.name=d_name;
		this.sex=d_sex;
		this.bed=d_bed;
		this.room=d_room;
		this.money=d_money;
		this.man=d_man;
		this.mz=d_mz;
		this.family=d_family;
		this.tellphone=d_tellphone;
		this.IDcard=d_IDcard;
		this.data=d_data;
		this.btn=btn;
	}

	@Override
	public void actionPerformed(ActionEvent e) {
		// TODO Auto-generated method stub
		if(e.getSource()==btn){
			Dao d=new Dao();
			d.old_update(name,sex,bed,room,money,man,mz,family,tellphone,IDcard,data);
		}		
	}

}
